package com.ktgj.customer.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ktgj.customer.mapper.CaseComplaintReasonMapper;
import com.ktgj.customer.domain.CaseComplaintReason;
import com.ktgj.customer.service.ICaseComplaintReasonService;

/**
 * 投诉工单_投诉原因Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-05-27
 */
@Service
public class CaseComplaintReasonServiceImpl implements ICaseComplaintReasonService 
{
    @Autowired
    private CaseComplaintReasonMapper caseComplaintReasonMapper;

    /**
     * 查询投诉工单_投诉原因
     * 
     * @param complaintReasonId 投诉工单_投诉原因ID
     * @return 投诉工单_投诉原因
     */
    @Override
    public CaseComplaintReason selectCaseComplaintReasonById(Long complaintReasonId)
    {
        return caseComplaintReasonMapper.selectCaseComplaintReasonById(complaintReasonId);
    }

    /**
     * 查询投诉工单_投诉原因列表
     * 
     * @param caseComplaintReason 投诉工单_投诉原因
     * @return 投诉工单_投诉原因
     */
    @Override
    public List<CaseComplaintReason> selectCaseComplaintReasonList(CaseComplaintReason caseComplaintReason)
    {
        return caseComplaintReasonMapper.selectCaseComplaintReasonList(caseComplaintReason);
    }

    /**
     * 新增投诉工单_投诉原因
     * 
     * @param caseComplaintReason 投诉工单_投诉原因
     * @return 结果
     */
    @Override
    public int insertCaseComplaintReason(CaseComplaintReason caseComplaintReason)
    {
        return caseComplaintReasonMapper.insertCaseComplaintReason(caseComplaintReason);
    }

    /**
     * 修改投诉工单_投诉原因
     * 
     * @param caseComplaintReason 投诉工单_投诉原因
     * @return 结果
     */
    @Override
    public int updateCaseComplaintReason(CaseComplaintReason caseComplaintReason)
    {
        return caseComplaintReasonMapper.updateCaseComplaintReason(caseComplaintReason);
    }

    /**
     * 批量删除投诉工单_投诉原因
     * 
     * @param complaintReasonIds 需要删除的投诉工单_投诉原因ID
     * @return 结果
     */
    @Override
    public int deleteCaseComplaintReasonByIds(Long[] complaintReasonIds)
    {
        return caseComplaintReasonMapper.deleteCaseComplaintReasonByIds(complaintReasonIds);
    }

    /**
     * 删除投诉工单_投诉原因信息
     * 
     * @param complaintReasonId 投诉工单_投诉原因ID
     * @return 结果
     */
    @Override
    public int deleteCaseComplaintReasonById(Long complaintReasonId)
    {
        return caseComplaintReasonMapper.deleteCaseComplaintReasonById(complaintReasonId);
    }
    /**
     *查询投诉工单_投诉原因列表
     * @return投诉工单_投诉原因集合
     */
    @Override
    public List<CaseComplaintReason> selectReasonList(){
        return  caseComplaintReasonMapper.selectReasonList();
    };
}
